<template>
	<view class="message-vison">
		<view class="search-view">
			<uni-search-bar class="search-bar" :focus="true" bgColor="#fff" radius="40" placeholder="搜索"
				clearButton="auto" cancelButton="none" @confirm="search" />
		</view>


		<view class="message-view">
			<view class="message-li" v-for="itme in wordList">
				<image class="avatar-icon" src="../../static/img/avatar.png" mode=""></image>
				<view class="name">
					{{itme.name}}
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				searchValue: '',
				wordList: [{
					avatar: '../../static/img/allocate-icon.png',
					name: '哈哈哈',

				}, {
					avatar: '../../static/img/allocate-icon.png',
					name: '哈哈哈',

				}, {
					avatar: '../../static/img/allocate-icon.png',
					name: '哈哈哈',

				}, {
					avatar: '../../static/img/allocate-icon.png',
					name: '哈哈哈',

				}, {
					avatar: '../../static/img/allocate-icon.png',
					name: '哈哈哈',

				}, ],
			}
		},
		onShareAppMessage() {},
		onNavigationBarButtonTap(e) {},

		watch: {},

		methods: {
			search(res) {
				uni.showToast({
					title: '搜索：' + res.value,
					icon: 'none'
				})
			},
		}
	}
</script>

<style lang="scss" scoped>
	.message-vison {
		padding-top: 30rpx;
	}

	.search-view {
		width: 92%;
		margin-left: 4%;
		margin-bottom: 30rpx;
	}

	@mixin main-view {
		width: 92%;
		margin-left: 4%;
		padding: 0 30rpx;
		background: #FFFFFF;
		border-radius: 10rpx;
		box-sizing: border-box;
	}

	.message-view {
		@include main-view;
		margin-bottom: 30rpx;

		.message-li {
			display: flex;
			align-items: center;

			box-sizing: border-box;
			height: 112rpx;
			width: 100%;
			// padding: 0 30rpx;
			

			.avatar-icon {
				width: 66rpx;
				height: 66rpx;
				margin-right: 20rpx;
			}

			.name {
				font-size: 28rpx;
				color: #333333;
				height: 112rpx;
				line-height: 112rpx;
				width: calc(100% - 86rpx);
				border-bottom: 1rpx solid #EEEEEE;
			}
		}
	}

	::v-deep {
		.uni-searchbar {
			padding: 0 !important;
		}
	}
</style>